<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>云课堂后台管理系统</title>
    <link rel="stylesheet" href="/stylesheets/common.css">
    <link rel="stylesheet" href="/layui/dist/css/layui.css">
    <script src="/layui/dist/layui.js"></script>
    <script src="/javascripts/backstage.js" type="module"></script>

</head>
<body>
    <div class="layui-layout layui-layout-admin">
        <div class="layui-header">
          <div class="layui-logo layui-hide-xs layui-bg-black" style="color: #fff;">云课堂后台</div>
          <!-- 头部区域（可配合layui 已有的水平导航） -->
          <ul class="layui-nav layui-layout-right">
            <li class="layui-nav-item layui-hide layui-show-md-inline-block">
              <a href="javascript:;">
                <img src="//tva1.sinaimg.cn/crop.0.0.118.118.180/5db11ff4gw1e77d3nqrv8j203b03cweg.jpg" class="layui-nav-img">
                <%= aname %>
              </a>
              <dl class="layui-nav-child">
                <dd><a id="logout">退出登录</a></dd>
              </dl>
            </li>
            <li class="layui-nav-item" lay-header-event="menuRight" lay-unselect>
              <a href="javascript:;">
                <i class="layui-icon layui-icon-more-vertical"></i>
              </a>
            </li>
          </ul>
        </div>
        
        <div class="layui-side layui-bg-black">
          <div class="layui-side-scroll">
            <!-- 左侧导航区域（可配合layui已有的垂直导航） -->
            <ul class="layui-nav layui-nav-tree" lay-filter="test">
                <!-- 侧边导航: <ul class="layui-nav layui-nav-tree layui-nav-side"> -->
                  <% roleArr.forEach(function(once){%>
                  <li class="layui-nav-item layui-nav-itemed">
                    <a href="<%= once.rule_url%>"><%=once.rule_name%></a>
                    
                    <% if (once.rule_name == '用户管理') {%>
                       <dl class="layui-nav-child">
                      <dd><a href="/backstage/teacher">教师管理</a></dd>
                      <dd><a href="/backstage/student">学生管理</a></dd>
                      <!-- <dd><a href="">跳转</a></dd> -->
                    </dl>
                    <%}%>
                   
                  </li>
                  <%})%>
                </ul>
        </div>
        </div>
        
        <div class="layui-body">
          <!-- 内容主体区域 -->
          <!-- <div style="padding: 15px;">内容主体区域。记得修改 layui.css 和 js 的路径</div> -->
        </div>
        
        <div class="layui-footer">
          <!-- 底部固定区域 -->
          底部固定区域
        </div>
      </div>

</body>
</html>